﻿using System;

namespace SpCop.Core
{
    public static class Helpers
    {
        public static T ParseEnumValue<T>(string text)
        {
            var o = Enum.Parse(typeof (T), text);
            if(o != null)
            return (T) o;

            return default(T);
        }
    }
}